<h1>Listing companies</h1>

<table>
  <thead>
    <tr>
      <th>Name</th>
      <th>Address</th>
      <th>Tel</th>
      <th>Fax</th>
      <th>Tax no</th>
      <th>Bank</th>
      <th>Bank account</th>
      <th>Bank address</th>
      <th colspan="3"></th>
    </tr>
  </thead>

  <tbody>
    <% @companies.each do |company| %>
      <tr>
        <td><%= company.name %></td>
        <td><%= company.address %></td>
        <td><%= company.tel %></td>
        <td><%= company.fax %></td>
        <td><%= company.bank %></td>
        <td><%= company.bank_account %></td>
        <td><%= company.bank_address %></td>
        <td><%= link_to 'Show', company %></td>
        <td><%= link_to 'Edit', edit_company_path(company) %></td>
        <td><%= link_to 'Destroy', company, method: :delete, data: { confirm: 'Are you sure?' } %></td>
      </tr>
    <% end %>
  </tbody>
</table>

<br>

<%= link_to 'New Company', new_company_path %>
